<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml">
		<head>
			<!-- template designed by Marco Von Ballmoos -->
			<title>Docs for page iHackyFunctions.php</title>
			<link rel="stylesheet" href="../media/stylesheet.css" />
			<meta http-equiv='Content-Type' content='text/html; charset=iso-8859-1'/>
		</head>
		<body>
			<div class="page-body">			
<h2 class="file-name"><img src="../media/images/Page_logo.png" alt="File" style="vertical-align: middle">/iHackyFunctions.php</h2>

<a name="sec-description"></a>
<div class="info-box">
	<div class="info-box-title">Description</div>
	<div class="nav-bar">
					<span class="disabled">Description</span> |
							<a href="#sec-classes">Classes</a>
			|							<a href="#sec-includes">Includes</a>
			|											<a href="#sec-functions">Functions</a>
			</div>
	<div class="info-box-body">	
		<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">File: iHackyFunctions.php</p>
<p class="description"><p>This file contains most of the functions that is used  throughout the application.</p></p>
		
			</div>
</div>
		
	<a name="sec-classes"></a>	
	<div class="info-box">
		<div class="info-box-title">Classes</div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
			<span class="disabled">Classes</span>
			|							<a href="#sec-includes">Includes</a>
				|																<a href="#sec-functions">Functions</a>
					</div>
		<div class="info-box-body">	
			<table cellpadding="2" cellspacing="0" class="class-table">
				<tr>
					<th class="class-table-header">Class</th>
					<th class="class-table-header">Description</th>
				</tr>
								<tr>
					<td style="padding-right: 2em; vertical-align: top; white-space: nowrap">
						<img src="../media/images/Class.png"
								 alt=" class"
								 title=" class"/>
						<a href="../default/Message.html">Message</a>
					</td>
					<td>
											Class to create a new message object.
										</td>
				</tr>
							</table>
		</div>
	</div>

	<a name="sec-includes"></a>	
	<div class="info-box">
		<div class="info-box-title">Includes</div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
							<a href="#sec-classes">Classes</a>
				|						<span class="disabled">Includes</span>
			|													<a href="#sec-functions">Functions</a>
					</div>
		<div class="info-box-body">	
			<a name="_messageboxclass_php"><!-- --></a>
<div class="oddrow">
	
	<div>
		<img src="../media/images/Page.png" alt=" " />
		<span class="include-title">
			<span class="include-type">include</span>
			(<span class="include-name"><a href="../default/_messageboxclass.php.html">'messageboxclass.php'</a></span>)
			(line <span class="line-number">11</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
	
</div>
		</div>
	</div>
	
	
	
	<a name="sec-functions"></a>	
	<div class="info-box">
		<div class="info-box-title">Functions</div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
							<a href="#sec-classes">Classes</a>
				|										<a href="#sec-includes">Includes</a>
				|												<span class="disabled">Functions</span>
		</div>
		<div class="info-box-body">	
			<a name="functioncheckUserExist" id="functioncheckUserExist"><!-- --></a>
<div class="evenrow">
	
	<div>
		<img src="../media/images/Function.png" />
		<span class="method-title">checkUserExist</span> (line <span class="line-number">549</span>)
	</div> 

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Function to check if current user is already in iHacky database.</p>
	<ul class="tags">
				<li><span class="field">return:</span> Returns true if user exist in iHacky database, false otherwise.</li>
			</ul>
	<div class="method-signature">
		<span class="method-result">Boolean</span>
		<span class="method-name">
			checkUserExist
		</span>
					(<span class="var-type">Int</span>&nbsp;<span class="var-name">$user</span>)
			</div>

			<ul class="parameters">
					<li>
				<span class="var-type">Int</span>
				<span class="var-name">$user</span><span class="var-description">: The facebook ID to match iHacky database ID.</span>			</li>
				</ul>
		
	
</div>
<a name="functioncloseDb" id="functioncloseDb"><!-- --></a>
<div class="oddrow">
	
	<div>
		<img src="../media/images/Function.png" />
		<span class="method-title">closeDb</span> (line <span class="line-number">29</span>)
	</div> 

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Function to close a connection with database specified by argument.</p>
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			closeDb
		</span>
					(<span class="var-type">Object</span>&nbsp;<span class="var-name">$conn</span>)
			</div>

			<ul class="parameters">
					<li>
				<span class="var-type">Object</span>
				<span class="var-name">$conn</span><span class="var-description">: The connection object to close.</span>			</li>
				</ul>
		
	
</div>
<a name="functioneditHackystatInfo" id="functioneditHackystatInfo"><!-- --></a>
<div class="evenrow">
	
	<div>
		<img src="../media/images/Function.png" />
		<span class="method-title">editHackystatInfo</span> (line <span class="line-number">787</span>)
	</div> 

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Prints the mock ajax FORM to edit the user's hackstat login info</p>
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			editHackystatInfo
		</span>
				()
			</div>

		
	
</div>
<a name="functionexpertiseTagCloud" id="functionexpertiseTagCloud"><!-- --></a>
<div class="oddrow">
	
	<div>
		<img src="../media/images/Function.png" />
		<span class="method-title">expertiseTagCloud</span> (line <span class="line-number">450</span>)
	</div> 

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Queries the database for all classes over rank 0 and stores each class as a key and a count of  all unique users associated with that class in a hashmap for a tag cloud.  Afterwards, it creates  an array of links where the key is the text and the count is the text size.</p>
	<ul class="tags">
				<li><span class="field">return:</span> of html links</li>
			</ul>
	<div class="method-signature">
		<span class="method-result">Array</span>
		<span class="method-name">
			expertiseTagCloud
		</span>
				()
			</div>

		
	
</div>
<a name="functiongetDbConn" id="functiongetDbConn"><!-- --></a>
<div class="evenrow">
	
	<div>
		<img src="../media/images/Function.png" />
		<span class="method-title">getDbConn</span> (line <span class="line-number">17</span>)
	</div> 

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Get a database connection specified by the config.php properties.</p>
	<ul class="tags">
				<li><span class="field">return:</span> database connection object.</li>
			</ul>
	<div class="method-signature">
		<span class="method-result">A</span>
		<span class="method-name">
			getDbConn
		</span>
				()
			</div>

		
	
</div>
<a name="functiongetNumUserClasses" id="functiongetNumUserClasses"><!-- --></a>
<div class="oddrow">
	
	<div>
		<img src="../media/images/Function.png" />
		<span class="method-title">getNumUserClasses</span> (line <span class="line-number">767</span>)
	</div> 

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Function to get the number of classes associated with the user</p>
	<ul class="tags">
				<li><span class="field">return:</span> The count of the number of classes associated with user</li>
			</ul>
	<div class="method-signature">
		<span class="method-result">Int</span>
		<span class="method-name">
			getNumUserClasses
		</span>
					(<span class="var-type">Int</span>&nbsp;<span class="var-name">$user</span>)
			</div>

			<ul class="parameters">
					<li>
				<span class="var-type">Int</span>
				<span class="var-name">$user</span><span class="var-description">: The facebook ID of the current user</span>			</li>
				</ul>
		
	
</div>
<a name="functionprintAddForm" id="functionprintAddForm"><!-- --></a>
<div class="evenrow">
	
	<div>
		<img src="../media/images/Function.png" />
		<span class="method-title">printAddForm</span> (line <span class="line-number">183</span>)
	</div> 

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Prints the hackystat info add form.  The form utilizes FBML mock ajax  functionality with the attributes clickrewriteurl, clickrewriteform,  clickrewriteid, clicktoshow and clicktohide.</p>
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			printAddForm
		</span>
				()
			</div>

		
	
</div>
<a name="functionprintBanner" id="functionprintBanner"><!-- --></a>
<div class="oddrow">
	
	<div>
		<img src="../media/images/Function.png" />
		<span class="method-title">printBanner</span> (line <span class="line-number">665</span>)
	</div> 

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Function to print the banner on each page. Different information  is displayed depending if the user exist in the iHacky database.</p>
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			printBanner
		</span>
					(<span class="var-type">Int</span>&nbsp;<span class="var-name">$user</span>)
			</div>

			<ul class="parameters">
					<li>
				<span class="var-type">Int</span>
				<span class="var-name">$user</span><span class="var-description">: The facebook ID of the current user</span>			</li>
				</ul>
		
	
</div>
<a name="functionprintDashboard" id="functionprintDashboard"><!-- --></a>
<div class="evenrow">
	
	<div>
		<img src="../media/images/Function.png" />
		<span class="method-title">printDashboard</span> (line <span class="line-number">47</span>)
	</div> 

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Prints fbml tags to render the dashboard.</p>
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			printDashboard
		</span>
				()
			</div>

		
	
</div>
<a name="functionprintFbmlTabs" id="functionprintFbmlTabs"><!-- --></a>
<div class="oddrow">
	
	<div>
		<img src="../media/images/Function.png" />
		<span class="method-title">printFbmlTabs</span> (line <span class="line-number">142</span>)
	</div> 

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Prints the FBML tags to render navigation tabs. A integer is passed in  to indicate which tab is highlighted.</p>
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			printFbmlTabs
		</span>
					(<span class="var-type">Int</span>&nbsp;<span class="var-name">$selection</span>)
			</div>

			<ul class="parameters">
					<li>
				<span class="var-type">Int</span>
				<span class="var-name">$selection</span><span class="var-description">: selection of the position number of tab to highlight starting from left.</span>			</li>
				</ul>
		
	
</div>
<a name="functionprintJavaScriptDiv" id="functionprintJavaScriptDiv"><!-- --></a>
<div class="evenrow">
	
	<div>
		<img src="../media/images/Function.png" />
		<span class="method-title">printJavaScriptDiv</span> (line <span class="line-number">119</span>)
	</div> 

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Prints the java script to make DIV sections collapse and uncollapse.</p>
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			printJavaScriptDiv
		</span>
				()
			</div>

		
	
</div>
<a name="functionprintSearchTable" id="functionprintSearchTable"><!-- --></a>
<div class="oddrow">
	
	<div>
		<img src="../media/images/Function.png" />
		<span class="method-title">printSearchTable</span> (line <span class="line-number">64</span>)
	</div> 

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Prints the HTML form for the class search box.</p>
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			printSearchTable
		</span>
				()
			</div>

		
	
</div>
<a name="functionprintTitle" id="functionprintTitle"><!-- --></a>
<div class="evenrow">
	
	<div>
		<img src="../media/images/Function.png" />
		<span class="method-title">printTitle</span> (line <span class="line-number">37</span>)
	</div> 

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Prints the fbml tags to set the page title.</p>
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			printTitle
		</span>
				()
			</div>

		
	
</div>
<a name="functionshowClasses" id="functionshowClasses"><!-- --></a>
<div class="oddrow">
	
	<div>
		<img src="../media/images/Function.png" />
		<span class="method-title">showClasses</span> (line <span class="line-number">219</span>)
	</div> 

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Prints the classes associated with the user.</p>
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			showClasses
		</span>
					(<span class="var-type">$facebook</span>&nbsp;<span class="var-name">$facebookId</span>, <span class="var-type">bool</span>&nbsp;<span class="var-name">$isProfileOwner</span>)
			</div>

			<ul class="parameters">
					<li>
				<span class="var-type">bool</span>
				<span class="var-name">$isProfileOwner</span><span class="var-description">: whether the current user is owner</span>			</li>
					<li>
				<span class="var-type">$facebook</span>
				<span class="var-name">$facebookId</span><span class="var-description">: The facebook ID of the user to display</span>			</li>
				</ul>
		
	
</div>
<a name="functionshowExpertiseTagCloud" id="functionshowExpertiseTagCloud"><!-- --></a>
<div class="evenrow">
	
	<div>
		<img src="../media/images/Function.png" />
		<span class="method-title">showExpertiseTagCloud</span> (line <span class="line-number">428</span>)
	</div> 

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Prints the Expertise Browser feature.</p>
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			showExpertiseTagCloud
		</span>
				()
			</div>

		
	
</div>
<a name="functiontestLogin" id="functiontestLogin"><!-- --></a>
<div class="oddrow">
	
	<div>
		<img src="../media/images/Function.png" />
		<span class="method-title">testLogin</span> (line <span class="line-number">733</span>)
	</div> 

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Function to test the hackystat login data of the user</p>
	<ul class="tags">
				<li><span class="field">return:</span> True if the data is valid, false otherwise</li>
			</ul>
	<div class="method-signature">
		<span class="method-result">Bool</span>
		<span class="method-name">
			testLogin
		</span>
					(<span class="var-type">$URI</span>&nbsp;<span class="var-name">$URI</span>, <span class="var-type">String</span>&nbsp;<span class="var-name">$username</span>, <span class="var-type">String</span>&nbsp;<span class="var-name">$password</span>)
			</div>

			<ul class="parameters">
					<li>
				<span class="var-type">String</span>
				<span class="var-name">$username</span><span class="var-description">: The user's hackystat username</span>			</li>
					<li>
				<span class="var-type">String</span>
				<span class="var-name">$password</span><span class="var-description">: The user's hackystat password</span>			</li>
					<li>
				<span class="var-type">$URI</span>
				<span class="var-name">$URI</span><span class="var-description">: The hackystat URI to test login</span>			</li>
				</ul>
		
	
</div>
		</div>
	</div>
	
	<p class="notes" id="credit">
		Documentation generated on Tue, 13 May 2008 02:22:18 -1000 by <a href="http://www.phpdoc.org" target="_blank">phpDocumentor 1.4.2</a>
	</p>
	</div></body>
</html>